package common.util;

import com.deepoove.poi.XWPFTemplate;
import com.deepoove.poi.policy.RenderPolicy;
import com.deepoove.poi.template.ElementTemplate;
import com.deepoove.poi.template.run.RunTemplate;
import org.apache.poi.xwpf.usermodel.XWPFRun;

public class EmRenderPolicy implements RenderPolicy {

    @Override
    public void render(ElementTemplate elementTemplate, Object o, XWPFTemplate xwpfTemplate) {
        XWPFRun run = ((RunTemplate) elementTemplate).getRun();
        // String thing = String.valueOf(data);
        String thing = "Hello, world";
        run.setText(thing, 0);
    }
}
